package org.jeecgframework.core.vo;

import java.util.ArrayList;
import java.util.List;

/**
 * 树形基础类
 * @author Administrator
 *
 */
public class TreeBean {
	private String id;
	
	private String parentid;
	
	private String name;
	
	private String nodesrc;
	 
	private List<TreeBean> childList;
	
	public void addChild(TreeBean node){
		childList.add(node);
	}
	
	public TreeBean(){
		childList = new ArrayList<TreeBean>();
		this.nodesrc = "";
	}
	
	public TreeBean(String id , String name , String parentid){
		this.id = id;
		this.name = name;
		this.parentid = parentid;		
		this.nodesrc = "";
		childList = new ArrayList<TreeBean>();
	}

	public String getId() {
		return id;
	}

	public void setId(String id) {
		this.id = id;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getParentid() {
		return parentid;
	}

	public void setParentid(String parentid) {
		this.parentid = parentid;
	}

	public List<TreeBean> getChildList() {
		return childList;
	}

	public void setChildList(List<TreeBean> childList) {
		this.childList = childList;
	}

	public String getNodesrc() {
		return nodesrc;
	}

	public void setNodesrc(String nodesrc) {
		this.nodesrc = nodesrc;
	}
	
	
}
